const { defineConfig } = require('@vue/cli-service')
const BASE_URL = process.env.NODE_ENV === "production" ? "/dc-ai-model/" : "./";
module.exports = defineConfig({
  transpileDependencies: true,
  publicPath: BASE_URL,
  outputDir: 'dist/',
  devServer: {
    proxy: {
      '/api': {
        target: 'https://aip.baidubce.com',
        changeOrigin: true,
        pathRewrite: { '^/api': '' },
        headers: {
          'Access-Control-Allow-Origin': '*'
        }
      }
    },
  }
})
